###timing reports
set REPORTS_DIR reports/${corner}
if {[file exist $REPORTS_DIR]} {
		file delete -force $REPORTS_DIR
}
file mkdir $REPORTS_DIR

set ports_clock_root {} 
foreach_in_collection a_clock [get_clocks -quiet] { 
  set src_ports [filter_collection [get_attribute $a_clock sources] @object_class==port] 
  set ports_clock_root  [add_to_collection $ports_clock_root $src_ports] 
}

group_path -name REG2OUT -to [all_outputs]
group_path -name REG2IN -from [remove_from_collection [all_inputs] $ports_clock_root]
group_path -name IN2OUT -from [remove_from_collection [all_inputs] $ports_clock_root] -to [all_outputs]
group_path -name REG2REG -from [all_registers] -to [all_registers]


report_annotated_parasitics -check > $REPORTS_DIR/annotation.rep
report_clock * > $REPORTS_DIR/clock_summary.rep
check_timing  > $REPORTS_DIR/check_timing.rep
check_timing -verbose  > $REPORTS_DIR/check_timing.verbose.rep

report_constraint -all_violators -nosplit > $REPORTS_DIR/constraint_all_violators.rep
if {$PBA_ENABLE} {
		report_constraint -all_violators -pba exhaustive -nosplit > $REPORTS_DIR/constraint_all_violators.pba.rep
}
report_constraint -all_violators -nosplit -max_transition > $REPORTS_DIR/max_transition.rep
report_constraint -all_violators -nosplit -max_capacitance > $REPORTS_DIR/max_capacitance.rep

report_timing -delay_type max -nets -transition_time -capacitance -crosstalk_delta -derate -max_paths 500 -nosplit > $REPORTS_DIR/setup_timing.rep
report_timing -delay_type max -nets -transition_time -capacitance -crosstalk_delta -derate -max_paths 500 -nosplit -path_type full_clock_expanded > $REPORTS_DIR/setup_timing.full_clock_expanded.rep
report_timing -delay_type min -nets -transition_time -capacitance -crosstalk_delta -derate -max_paths 500 -nosplit > $REPORTS_DIR/hold_timing.rep
report_timing -delay_type min -nets -transition_time -capacitance -crosstalk_delta -derate -max_paths 500 -nosplit -path_type full_clock_expanded > $REPORTS_DIR/hold_timing.full_clock_expanded.rep
if {$PBA_ENABLE} {
		report_timing -delay_type max -nets -transition_time -capacitance -crosstalk_delta -derate -max_paths 100 -pba exhaustive -nosplit > $REPORTS_DIR/setup_timing.pba.rep
		report_timing -delay_type max -nets -transition_time -capacitance -crosstalk_delta -derate -max_paths 100 -pba exhaustive -nosplit -path_type full_clock_expanded > $REPORTS_DIR/setup_timing.full_clock_expanded.pba.rep
		report_timing -delay_type min -nets -transition_time -capacitance -crosstalk_delta -derate -max_paths 100 -pba exhaustive -nosplit > $REPORTS_DIR/hold_timing.pba.rep
		report_timing -delay_type min -nets -transition_time -capacitance -crosstalk_delta -derate -max_paths 100 -pba exhaustive -nosplit -path_type full_clock_expanded > $REPORTS_DIR/hold_timing.full_clock_expanded.pba.rep
}








